<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Mpost extends CI_Model {
/*	function mpost(){
        parent::Model();
        $this->load->database();
    }*/

    function ambil_data(){
        $this->db->select('id_kategori, cara');
        $ambil = $this->db->from('tbl_makanan')->get();
        $this->db->limit(1);
        if($ambil->num_rows() > 0)
   {
   foreach($ambil->result() as $baris)
    {
     $hasil[] = $baris;
    }
    return $hasil;
   }
        return $this->db->get();
    }
}
